/*
 * Case.cpp
 *
 *  Created on: 29/05/2011
 *      Author: godinho
 */

#include <controller/Case.h>
#include <math.h>
#include <iostream>

Case::Case() {
	this->mDna = 0;
	reset();
}

Case::~Case() {
	if(this->mDna != 0) {
		delete mDna;
	}
}

unsigned char Case::getLocalGreenExtension() const {
       return mLocalGreenExtension;
}

unsigned char Case::getLocalQueue() const {
   return mLocalQueue;
}

unsigned char Case::getLocalSideQueue() const {
   return mLocalSideQueue;
}

unsigned char Case::getLocalSideTime() const {
   return mLocalSideTime;
}

unsigned char Case::getLocalTime() const {
   return mLocalTime;
}

unsigned char Case::getNextGreenExtension() const {
   return mNextGreenExtension;
}

unsigned char Case::getNextQueue() const {
   return mNextQueue;
}

unsigned char Case::getNextSideGreenExtension() const {
   return mNextSideGreenExtension;
}

unsigned char Case::getNextSideQueue() const {
   return mNextSideQueue;
}

unsigned char Case::getNextSideTime() const {
   return mNextSideTime;
}

unsigned char Case::getNextTime() const {
   return mNextTime;
}

unsigned char Case::getPrefiousQueue() const {
   return mPrefiousQueue;
}

unsigned char Case::getPreviousGreenExtension() const {
   return mPreviousGreenExtension;
}

unsigned char Case::getPreviousSideGreenExtension() const {
   return mPreviousSideGreenExtension;
}

unsigned char Case::getPreviousSideQueue() const {
   return mPreviousSideQueue;
}

unsigned char Case::getPreviousSideTime() const {
   return mPreviousSideTime;
}

unsigned char Case::getPreviousTime() const {
   return mPreviousTime;
}

unsigned char Case::getResultLocalQueue() const {
   return mResultLocalQueue;
}

unsigned char Case::getResultLocalSideQueue() const {
   return mResultLocalSideQueue;
}

unsigned char Case::getResultNextQueue() const  {
   return mResultNextQueue;
}

unsigned char Case::getResultNextSideQueue() const {
   return mResultNextSideQueue;
}

unsigned char Case::getResultPreviousQueue() const {
   return mResultPreviousQueue;
}

float Case::getFitness() const {
	return this->mFitness;
}

float Case::getSimilarity() {
	return this->mSimilarity;
}

int Case::getId(){
	return this->mId;
}

Dna* Case::getDna() {
	return this->mDna;
}

void Case::setLocalGreenExtension(unsigned char mLocalGreenExtension) {
   this->mLocalGreenExtension = mLocalGreenExtension;
}

void Case::setLocalQueue(unsigned char mLocalQueue) {
   this->mLocalQueue = mLocalQueue;
}

void Case::setLocalSideQueue(unsigned char mLocalSideQueue) {
   this->mLocalSideQueue = mLocalSideQueue;
}

void Case::setLocalSideTime(unsigned char mLocalSideTime) {
   this->mLocalSideTime = mLocalSideTime;
}

void Case::setLocalTime(unsigned char mLocalTime) {
   this->mLocalTime = mLocalTime;
}

void Case::setNextGreenExtension(unsigned char mNextGreenExtension) {
   this->mNextGreenExtension = mNextGreenExtension;
}

void Case::setNextQueue(unsigned char mNextQueue) {
   this->mNextQueue = mNextQueue;
}

void Case::setNextSideGreenExtension(unsigned char mNextSideGreenExtension) {
   this->mNextSideGreenExtension = mNextSideGreenExtension;
}

void Case::setNextSideQueue(unsigned char mNextSideQueue) {
   this->mNextSideQueue = mNextSideQueue;
}

void Case::setNextSideTime(unsigned char mNextSideTime) {
   this->mNextSideTime = mNextSideTime;
}

void Case::setNextTime(unsigned char mNextTime) {
   this->mNextTime = mNextTime;
}

void Case::setPrefiousQueue(unsigned char mPrefiousQueue) {
   this->mPrefiousQueue = mPrefiousQueue;
}

void Case::setPreviousGreenExtension(unsigned char mPreviousGreenExtension) {
   this->mPreviousGreenExtension = mPreviousGreenExtension;
}

void Case::setPreviousSideGreenExtension(unsigned char mPreviousSideGreenExtension) {
   this->mPreviousSideGreenExtension = mPreviousSideGreenExtension;
}

void Case::setPreviousSideQueue(unsigned char mPreviousSideQueue) {
   this->mPreviousSideQueue = mPreviousSideQueue;
}

void Case::setPreviousSideTime(unsigned char mPreviousSideTime) {
   this->mPreviousSideTime = mPreviousSideTime;
}

void Case::setPreviousTime(unsigned char mPreviousTime) {
   this->mPreviousTime = mPreviousTime;
}

void Case::setResultLocalQueue(unsigned char mResultLocalQueue) {
   this->mResultLocalQueue = mResultLocalQueue;
}

void Case::setResultLocalSideQueue(unsigned char mResultLocalSideQueue) {
   this->mResultLocalSideQueue = mResultLocalSideQueue;
}

void Case::setResultNextQueue(unsigned char mResultNextQueue) {
   this->mResultNextQueue = mResultNextQueue;
}

void Case::setResultNextSideQueue(unsigned char mResultNextSideQueue) {
   this->mResultNextSideQueue = mResultNextSideQueue;
}

void Case::setResultPreviousQueue(unsigned char mResultPreviousQueue) {
   this->mResultPreviousQueue = mResultPreviousQueue;
}

void Case::setFitness(float f) {
	this->mFitness = f;
}

void Case::setSimilarity(float s) {
	this->mSimilarity = s;
}

void Case::setId(int id) {
	this->mId = id;
}

void Case::setDna(Dna* dna) {
	this->mDna = dna;
}

void Case::reset() {
    mId = 0;
    mLocalGreenExtension = 0;
    mLocalQueue = 0;
    mLocalSideQueue = 0;
    mLocalSideTime = 0;
    mLocalTime = 0;
    mNextGreenExtension = 0;
    mNextQueue = 0;
    mNextSideGreenExtension = 0;
    mNextSideQueue = 0;
    mNextSideTime = 0;
    mNextTime = 0;
    mPrefiousQueue = 0;
    mPreviousGreenExtension = 0;
    mPreviousSideGreenExtension = 0;
    mPreviousSideQueue = 0;
    mPreviousSideTime = 0;
    mPreviousTime = 0;
    mResultLocalQueue = 0;
    mResultLocalSideQueue = 0;
    mResultNextQueue = 0;
    mResultNextSideQueue = 0;
    mResultPreviousQueue = 0;
    mFitness = 0;
    mSimilarity = 0;
}
